class Greeter {
    static standardGreeting ="Hello , there" 

    greeting:string
    
    constructor(message?:string){
        this.greeting=message
    }
    greet(){
        if(this.greeting){
            return 'Hello,'+this.greeting
        }else{
            return Greeter.standardGreeting
        }
    }
}

let greeter : Greeter  //变量类型是Greeter类型
greeter = new Greeter('world')
console.log(greeter.greet())
let greeterMaker:typeof Greeter=Greeter
greeterMaker.standardGreeting='Hey there'